package com.library.admin.manager;

import com.library.admin.listener.FindSubscriberByLoginListener;
import com.vaadin.ui.Button;
import com.vaadin.ui.TextField;
import com.vaadin.ui.VerticalLayout;

public class SubscriberManagerPanel extends VerticalLayout {
	private static final long serialVersionUID = -1026048564972633781L;
	
	private TextField subscriberLogin;
	private Button submitButton;

	public SubscriberManagerPanel() {
		init();
	}

	public void init() {
		setSpacing(true);
		setMargin(true, false, false, false);
		subscriberLogin = new TextField("Veuillez saisir le login de l'abonné que vous voulez modifier");
		submitButton = new Button("OK");
		
		submitButton.addListener(new FindSubscriberByLoginListener(this));
		
		addComponent(subscriberLogin);
		addComponent(submitButton);
	}

	public TextField getSubscriberLogin() {
		return subscriberLogin;
	}
}
